home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / progba_1 / frmdemo.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1999-01-05  |  28.2 KB  |  822 lines

  1. VERSION 5.00
  2. Object = "{F9043C88-F6F2-101A-A3C9-08002B2F49FB}#1.2#0"; "COMDLG32.OCX"
  3. Begin VB.Form frmProgressBarDemo 
  4.    BorderStyle     =   3  'Fixed Dialog
  5.    Caption         =   "ProgBar Control V1.2.1 Demo"
  6.    ClientHeight    =   7785
  7.    ClientLeft      =   45
  8.    ClientTop       =   330
  9.    ClientWidth     =   8760
  10.    ClipControls    =   0   'False
  11.    LinkTopic       =   "Form1"
  12.    MaxButton       =   0   'False
  13.    MinButton       =   0   'False
  14.    ScaleHeight     =   7785
  15.    ScaleWidth      =   8760
  16.    ShowInTaskbar   =   0   'False
  17.    StartUpPosition =   2  'CenterScreen
  18.    Begin NEProgBar.ProgBar ProgBar12 
  19.       Align           =   4  'Align Right
  20.       Height          =   6795
  21.       Left            =   8265
  22.       Top             =   495
  23.       Width           =   495
  24.       _ExtentX        =   873
  25.       _ExtentY        =   11986
  26.       FillDirection   =   1
  27.       Message         =   "Hello"
  28.       ShowMessage     =   -1  'True
  29.       ShowPercent     =   -1  'True
  30.       VerticalText    =   -1  'True
  31.    End
  32.    Begin NEProgBar.ProgBar ProgBar11 
  33.       Align           =   2  'Align Bottom
  34.       Height          =   495
  35.       Left            =   0
  36.       Top             =   7290
  37.       Width           =   8760
  38.       _ExtentX        =   15452
  39.       _ExtentY        =   873
  40.       FillDirection   =   2
  41.       ShowMessage     =   -1  'True
  42.       ShowPercent     =   -1  'True
  43.    End
  44.    Begin NEProgBar.ProgBar ProgBar10 
  45.       Align           =   1  'Align Top
  46.       Height          =   495
  47.       Left            =   0
  48.       Top             =   0
  49.       Width           =   8760
  50.       _ExtentX        =   15452
  51.       _ExtentY        =   873
  52.       Message         =   "Hello"
  53.       ShowMessage     =   -1  'True
  54.       ShowPercent     =   -1  'True
  55.    End
  56.    Begin NEProgBar.ProgBar ProgBar9 
  57.       Align           =   3  'Align Left
  58.       Height          =   6795
  59.       Left            =   0
  60.       Top             =   495
  61.       Width           =   495
  62.       _ExtentX        =   873
  63.       _ExtentY        =   11986
  64.       FillDirection   =   0
  65.       Message         =   "Hello"
  66.       ShowMessage     =   -1  'True
  67.       ShowPercent     =   -1  'True
  68.       VerticalText    =   -1  'True
  69.    End
  70.    Begin VB.Frame Frame3 
  71.       Caption         =   "Down"
  72.       Height          =   4335
  73.       Left            =   6840
  74.       TabIndex        =   27
  75.       Top             =   480
  76.       Width           =   1335
  77.       Begin NEProgBar.ProgBar ProgBar3 
  78.          Height          =   3975
  79.          Left            =   120
  80.          Top             =   240
  81.          Width           =   495
  82.          _ExtentX        =   873
  83.          _ExtentY        =   7011
  84.          FillDirection   =   1
  85.          Message         =   "Hello"
  86.          ShowMessage     =   -1  'True
  87.          ShowPercent     =   -1  'True
  88.          VerticalText    =   -1  'True
  89.       End
  90.       Begin NEProgBar.ProgBar ProgBar4 
  91.          Height          =   3975
  92.          Left            =   720
  93.          Top             =   240
  94.          Width           =   495
  95.          _ExtentX        =   873
  96.          _ExtentY        =   7011
  97.          BorderStyle     =   0
  98.          FillDirection   =   1
  99.          Message         =   "Hello"
  100.          ShowMessage     =   -1  'True
  101.          ShowPercent     =   -1  'True
  102.          VerticalText    =   -1  'True
  103.       End
  104.    End
  105.    Begin VB.Frame Frame2 
  106.       Caption         =   "Up"
  107.       Height          =   4335
  108.       Left            =   5400
  109.       TabIndex        =   26
  110.       Top             =   480
  111.       Width           =   1335
  112.       Begin NEProgBar.ProgBar ProgBar1 
  113.          Height          =   3975
  114.          Left            =   120
  115.          Top             =   240
  116.          Width           =   495
  117.          _ExtentX        =   873
  118.          _ExtentY        =   7011
  119.          FillDirection   =   0
  120.          Message         =   "Hello"
  121.          ShowMessage     =   -1  'True
  122.          ShowPercent     =   -1  'True
  123.          VerticalText    =   -1  'True
  124.       End
  125.       Begin NEProgBar.ProgBar ProgBar2 
  126.          Height          =   3975
  127.          Left            =   720
  128.          Top             =   240
  129.          Width           =   495
  130.          _ExtentX        =   873
  131.          _ExtentY        =   7011
  132.          BorderStyle     =   0
  133.          FillDirection   =   0
  134.          Message         =   "Hello"
  135.          ShowMessage     =   -1  'True
  136.          ShowPercent     =   -1  'True
  137.          VerticalText    =   -1  'True
  138.       End
  139.    End
  140.    Begin VB.Frame Frame1 
  141.       Caption         =   "Options"
  142.       Height          =   4335
  143.       Left            =   600
  144.       TabIndex        =   16
  145.       Top             =   480
  146.       Width           =   4695
  147.       Begin VB.CheckBox chkWaitForSound 
  148.          Caption         =   "Wait for sound"
  149.          Enabled         =   0   'False
  150.          Height          =   255
  151.          Left            =   2040
  152.          TabIndex        =   9
  153.          Top             =   2040
  154.          Width           =   1695
  155.       End
  156.       Begin VB.CommandButton cmdSoundToPlay 
  157.          Caption         =   "Sound"
  158.          Enabled         =   0   'False
  159.          Height          =   255
  160.          Left            =   3840
  161.          TabIndex        =   10
  162.          Top             =   2280
  163.          Width           =   735
  164.       End
  165.       Begin VB.TextBox txtSoundToPlay 
  166.          Enabled         =   0   'False
  167.          Height          =   285
  168.          Left            =   240
  169.          TabIndex        =   37
  170.          TabStop         =   0   'False
  171.          Top             =   2280
  172.          Width           =   3495
  173.       End
  174.       Begin VB.CheckBox chkPlaySound 
  175.          Caption         =   "Play sound @ 100%"
  176.          Height          =   255
  177.          Left            =   240
  178.          TabIndex        =   8
  179.          Top             =   2040
  180.          Width           =   1935
  181.       End
  182.       Begin VB.TextBox txtColour4 
  183.          BackColor       =   &H00FF0000&
  184.          Height          =   285
  185.          Left            =   3480
  186.          Locked          =   -1  'True
  187.          TabIndex        =   36
  188.          TabStop         =   0   'False
  189.          Top             =   3840
  190.          Width           =   1095
  191.       End
  192.       Begin VB.TextBox txtColour3 
  193.          BackColor       =   &H00000000&
  194.          Height          =   285
  195.          Left            =   3480
  196.          Locked          =   -1  'True
  197.          TabIndex        =   35
  198.          TabStop         =   0   'False
  199.          Top             =   3480
  200.          Width           =   1095
  201.       End
  202.       Begin VB.TextBox txtColour2 
  203.          BackColor       =   &H000000FF&
  204.          Height          =   285
  205.          Left            =   3480
  206.          Locked          =   -1  'True
  207.          TabIndex        =   34
  208.          TabStop         =   0   'False
  209.          Top             =   3120
  210.          Width           =   1095
  211.       End
  212.       Begin VB.TextBox txtColour1 
  213.          BackColor       =   &H00FFFFFF&
  214.          Height          =   285
  215.          Left            =   3480
  216.          Locked          =   -1  'True
  217.          TabIndex        =   33
  218.          TabStop         =   0   'False
  219.          Top             =   2760
  220.          Width           =   1095
  221.       End
  222.       Begin VB.CheckBox chkGradient 
  223.          Caption         =   "Gradient"
  224.          Height          =   255
  225.          Left            =   2040
  226.          TabIndex        =   7
  227.          Top             =   1800
  228.          Width           =   1095
  229.       End
  230.       Begin VB.CheckBox chkSolid 
  231.          Caption         =   "Solid"
  232.          Height          =   255
  233.          Left            =   240
  234.          TabIndex        =   6
  235.          Top             =   1800
  236.          Value           =   1  'Checked
  237.          Width           =   735
  238.       End
  239.       Begin VB.CommandButton cmdRunBars 
  240.          Caption         =   "Run Bars"
  241.          Height          =   615
  242.          Left            =   3480
  243.          TabIndex        =   15
  244.          Top             =   1320
  245.          Width           =   975
  246.       End
  247.       Begin VB.TextBox txtBarEndColour 
  248.          Height          =   285
  249.          Left            =   1440
  250.          Locked          =   -1  'True
  251.          TabIndex        =   31
  252.          TabStop         =   0   'False
  253.          Text            =   "&H00000000&"
  254.          Top             =   3480
  255.          Width           =   1215
  256.       End
  257.       Begin VB.CommandButton Command4 
  258.          Caption         =   "Colour"
  259.          Height          =   255
  260.          Left            =   2760
  261.          TabIndex        =   13
  262.          Top             =   3480
  263.          Width           =   615
  264.       End
  265.       Begin VB.CommandButton Command3 
  266.          Caption         =   "Colour"
  267.          Height          =   255
  268.          Left            =   2760
  269.          TabIndex        =   14
  270.          Top             =   3840
  271.          Width           =   615
  272.       End
  273.       Begin VB.CommandButton Command2 
  274.          Caption         =   "Colour"
  275.          Height          =   255
  276.          Left            =   2760
  277.          TabIndex        =   12
  278.          Top             =   3120
  279.          Width           =   615
  280.       End
  281.       Begin VB.CommandButton Command1 
  282.          Caption         =   "Colour"
  283.          Height          =   255
  284.          Left            =   2760
  285.          TabIndex        =   11
  286.          Top             =   2760
  287.          Width           =   615
  288.       End
  289.       Begin MSComDlg.CommonDialog CommonDialog1 
  290.          Left            =   2520
  291.          Top             =   480
  292.          _ExtentX        =   847
  293.          _ExtentY        =   847
  294.          _Version        =   393216
  295.       End
  296.       Begin VB.TextBox txtFontColour 
  297.          Height          =   285
  298.          Left            =   1440
  299.          Locked          =   -1  'True
  300.          TabIndex        =   25
  301.          TabStop         =   0   'False
  302.          Text            =   "&H00FF0000&"
  303.          Top             =   3840
  304.          Width           =   1215
  305.       End
  306.       Begin VB.TextBox txtBackColour 
  307.          Height          =   285
  308.          Left            =   1440
  309.          Locked          =   -1  'True
  310.          TabIndex        =   23
  311.          TabStop         =   0   'False
  312.          Text            =   "&H00FFFFFF&"
  313.          Top             =   2760
  314.          Width           =   1215
  315.       End
  316.       Begin VB.CheckBox chkShowValue 
  317.          Caption         =   "Show value"
  318.          Height          =   255
  319.          Left            =   2040
  320.          TabIndex        =   5
  321.          Top             =   1560
  322.          Width           =   1335
  323.       End
  324.       Begin VB.TextBox txtBarStartColour 
  325.          Height          =   285
  326.          Left            =   1440
  327.          Locked          =   -1  'True
  328.          TabIndex        =   20
  329.          TabStop         =   0   'False
  330.          Text            =   "&H000000FF&"
  331.          Top             =   3120
  332.          Width           =   1215
  333.       End
  334.       Begin VB.CheckBox chkShowPercentage 
  335.          Caption         =   "Show percentage"
  336.          Height          =   255
  337.          Left            =   240
  338.          TabIndex        =   4
  339.          Top             =   1560
  340.          Value           =   1  'Checked
  341.          Width           =   1695
  342.       End
  343.       Begin VB.CheckBox chkShowMessage 
  344.          Caption         =   "Show message"
  345.          Height          =   255
  346.          Left            =   240
  347.          TabIndex        =   3
  348.          Top             =   1320
  349.          Value           =   1  'Checked
  350.          Width           =   1455
  351.       End
  352.       Begin VB.TextBox txtMessage 
  353.          Height          =   285
  354.          Left            =   1080
  355.          TabIndex        =   2
  356.          Text            =   "Hello"
  357.          Top             =   960
  358.          Width           =   3375
  359.       End
  360.       Begin VB.TextBox txtUpperLimit 
  361.          Height          =   285
  362.          Left            =   1080
  363.          TabIndex        =   1
  364.          Text            =   "100"
  365.          Top             =   600
  366.          Width           =   1335
  367.       End
  368.       Begin VB.TextBox txtLowerLimit 
  369.          Height          =   285
  370.          Left            =   1080
  371.          TabIndex        =   0
  372.          Text            =   "0"
  373.          Top             =   240
  374.          Width           =   1335
  375.       End
  376.       Begin VB.Label Label8 
  377.          Alignment       =   1  'Right Justify
  378.          Caption         =   "Bar End Colour:"
  379.          Height          =   255
  380.          Left            =   120
  381.          TabIndex        =   32
  382.          Top             =   3480
  383.          Width           =   1215
  384.       End
  385.       Begin VB.Label Label7 
  386.          Alignment       =   1  'Right Justify
  387.          Caption         =   "(C) NE 1998"
  388.          Height          =   255
  389.          Left            =   3360
  390.          TabIndex        =   30
  391.          Top             =   360
  392.          Width           =   1095
  393.       End
  394.       Begin VB.Label Label6 
  395.          Alignment       =   1  'Right Justify
  396.          Caption         =   "Font Colour:"
  397.          Height          =   255
  398.          Left            =   360
  399.          TabIndex        =   24
  400.          Top             =   3840
  401.          Width           =   975
  402.       End
  403.       Begin VB.Label Label5 
  404.          Alignment       =   1  'Right Justify
  405.          Caption         =   "Back Colour:"
  406.          Height          =   375
  407.          Left            =   360
  408.          TabIndex        =   22
  409.          Top             =   2760
  410.          Width           =   975
  411.       End
  412.       Begin VB.Label Label4 
  413.          Alignment       =   1  'Right Justify
  414.          Caption         =   "Bar Start Colour:"
  415.          Height          =   255
  416.          Left            =   120
  417.          TabIndex        =   21
  418.          Top             =   3120
  419.          Width           =   1215
  420.       End
  421.       Begin VB.Label Label3 
  422.          Alignment       =   1  'Right Justify
  423.          Caption         =   "Message:"
  424.          Height          =   255
  425.          Left            =   120
  426.          TabIndex        =   19
  427.          Top             =   960
  428.          Width           =   855
  429.       End
  430.       Begin VB.Label Label2 
  431.          Alignment       =   1  'Right Justify
  432.          Caption         =   "Upper limit:"
  433.          Height          =   255
  434.          Left            =   120
  435.          TabIndex        =   18
  436.          Top             =   600
  437.          Width           =   855
  438.       End
  439.       Begin VB.Label Label1 
  440.          Alignment       =   1  'Right Justify
  441.          Caption         =   "Lower limit:"
  442.          Height          =   255
  443.          Left            =   120
  444.          TabIndex        =   17
  445.          Top             =   240
  446.          Width           =   855
  447.       End
  448.    End
  449.    Begin VB.Frame Frame4 
  450.       Caption         =   "Left"
  451.       Height          =   1215
  452.       Left            =   600
  453.       TabIndex        =   28
  454.       Top             =   4800
  455.       Width           =   7575
  456.       Begin NEProgBar.ProgBar ProgBar5 
  457.          Height          =   375
  458.          Left            =   120
  459.          Top             =   240
  460.          Width           =   7335
  461.          _ExtentX        =   12938
  462.          _ExtentY        =   661
  463.          FillDirection   =   2
  464.          Message         =   "Hello"
  465.          ShowMessage     =   -1  'True
  466.          ShowPercent     =   -1  'True
  467.       End
  468.       Begin NEProgBar.ProgBar ProgBar6 
  469.          Height          =   375
  470.          Left            =   120
  471.          Top             =   720
  472.          Width           =   7335
  473.          _ExtentX        =   12938
  474.          _ExtentY        =   661
  475.          BorderStyle     =   0
  476.          FillDirection   =   2
  477.          Message         =   "Hello"
  478.          ShowMessage     =   -1  'True
  479.          ShowPercent     =   -1  'True
  480.       End
  481.    End
  482.    Begin VB.Frame Frame5 
  483.       Caption         =   "Right"
  484.       Height          =   1215
  485.       Left            =   600
  486.       TabIndex        =   29
  487.       Top             =   6000
  488.       Width           =   7575
  489.       Begin NEProgBar.ProgBar ProgBar7 
  490.          Height          =   375
  491.          Left            =   120
  492.          Top             =   240
  493.          Width           =   7335
  494.          _ExtentX        =   12938
  495.          _ExtentY        =   661
  496.          Message         =   "Hello"
  497.          ShowMessage     =   -1  'True
  498.          ShowPercent     =   -1  'True
  499.       End
  500.       Begin NEProgBar.ProgBar ProgBar8 
  501.          Height          =   375
  502.          Left            =   120
  503.          Top             =   720
  504.          Width           =   7335
  505.          _ExtentX        =   12938
  506.          _ExtentY        =   661
  507.          BorderStyle     =   0
  508.          Message         =   "Hello"
  509.          ShowMessage     =   -1  'True
  510.          ShowPercent     =   -1  'True
  511.       End
  512.    End
  513. Attribute VB_Name = "frmProgressBarDemo"
  514. Attribute VB_GlobalNameSpace = False
  515. Attribute VB_Creatable = False
  516. Attribute VB_PredeclaredId = True
  517. Attribute VB_Exposed = False
  518. Option Explicit
  519. Private Sub chkGradient_Click()
  520.     If chkGradient.Value = Checked Then
  521.         chkSolid.Value = Unchecked
  522.         ProgBar1.BarStyle = pbGradient
  523.         ProgBar2.BarStyle = pbGradient
  524.         ProgBar3.BarStyle = pbGradient
  525.         ProgBar4.BarStyle = pbGradient
  526.         ProgBar5.BarStyle = pbGradient
  527.         ProgBar6.BarStyle = pbGradient
  528.         ProgBar7.BarStyle = pbGradient
  529.         ProgBar8.BarStyle = pbGradient
  530.         ProgBar9.BarStyle = pbGradient
  531.         ProgBar10.BarStyle = pbGradient
  532.         ProgBar11.BarStyle = pbGradient
  533.         ProgBar12.BarStyle = pbGradient
  534.     Else
  535.         chkSolid.Value = Checked
  536.         chkSolid_Click
  537.     End If
  538. End Sub
  539. Private Sub chkPlaySound_Click()
  540.     If chkPlaySound.Value = Checked Then
  541.         txtSoundToPlay.Enabled = True
  542.         cmdSoundToPlay.Enabled = True
  543.         chkWaitForSound.Enabled = True
  544.         ProgBar12.PlaySound = True
  545.     Else
  546.         txtSoundToPlay.Enabled = False
  547.         cmdSoundToPlay.Enabled = False
  548.         chkWaitForSound.Enabled = False
  549.         ProgBar12.PlaySound = False
  550.     End If
  551. End Sub
  552. Private Sub chkShowMessage_Click()
  553.     'Turn the message on or off.
  554.     ProgBar1.ShowMessage = chkShowMessage.Value
  555.     ProgBar2.ShowMessage = chkShowMessage.Value
  556.     ProgBar3.ShowMessage = chkShowMessage.Value
  557.     ProgBar4.ShowMessage = chkShowMessage.Value
  558.     ProgBar5.ShowMessage = chkShowMessage.Value
  559.     ProgBar6.ShowMessage = chkShowMessage.Value
  560.     ProgBar7.ShowMessage = chkShowMessage.Value
  561.     ProgBar8.ShowMessage = chkShowMessage.Value
  562.     ProgBar9.ShowMessage = chkShowMessage.Value
  563.     ProgBar10.ShowMessage = chkShowMessage.Value
  564.     ProgBar11.ShowMessage = chkShowMessage.Value
  565.     ProgBar12.ShowMessage = chkShowMessage.Value
  566. End Sub
  567. Private Sub chkShowPercentage_Click()
  568.     'Make sure only the percentage OR the value is chosen.
  569.     If chkShowPercentage.Value = Checked Then
  570.         chkShowValue.Value = Unchecked
  571.     End If
  572.     'Set the percentage on or off.
  573.     ProgBar1.ShowPercent = chkShowPercentage.Value
  574.     ProgBar2.ShowPercent = chkShowPercentage.Value
  575.     ProgBar3.ShowPercent = chkShowPercentage.Value
  576.     ProgBar4.ShowPercent = chkShowPercentage.Value
  577.     ProgBar5.ShowPercent = chkShowPercentage.Value
  578.     ProgBar6.ShowPercent = chkShowPercentage.Value
  579.     ProgBar7.ShowPercent = chkShowPercentage.Value
  580.     ProgBar8.ShowPercent = chkShowPercentage.Value
  581.     ProgBar9.ShowPercent = chkShowPercentage.Value
  582.     ProgBar10.ShowPercent = chkShowPercentage.Value
  583.     ProgBar11.ShowPercent = chkShowPercentage.Value
  584.     ProgBar12.ShowPercent = chkShowPercentage.Value
  585. End Sub
  586. Private Sub chkShowValue_Click()
  587.     'Make sure only the percentage OR the value is chosen.
  588.     If chkShowValue.Value = Checked Then
  589.         chkShowPercentage.Value = Unchecked
  590.     End If
  591.     'Set the value on or off.
  592.     ProgBar1.ShowValue = chkShowValue.Value
  593.     ProgBar2.ShowValue = chkShowValue.Value
  594.     ProgBar3.ShowValue = chkShowValue.Value
  595.     ProgBar4.ShowValue = chkShowValue.Value
  596.     ProgBar5.ShowValue = chkShowValue.Value
  597.     ProgBar6.ShowValue = chkShowValue.Value
  598.     ProgBar7.ShowValue = chkShowValue.Value
  599.     ProgBar8.ShowValue = chkShowValue.Value
  600.     ProgBar9.ShowValue = chkShowValue.Value
  601.     ProgBar10.ShowValue = chkShowValue.Value
  602.     ProgBar11.ShowValue = chkShowValue.Value
  603.     ProgBar12.ShowValue = chkShowValue.Value
  604. End Sub
  605. Private Sub chkSolid_Click()
  606.     If chkSolid.Value = Checked Then
  607.         chkGradient.Value = Unchecked
  608.         ProgBar1.BarStyle = pbSolid
  609.         ProgBar2.BarStyle = pbSolid
  610.         ProgBar3.BarStyle = pbSolid
  611.         ProgBar4.BarStyle = pbSolid
  612.         ProgBar5.BarStyle = pbSolid
  613.         ProgBar6.BarStyle = pbSolid
  614.         ProgBar7.BarStyle = pbSolid
  615.         ProgBar8.BarStyle = pbSolid
  616.         ProgBar9.BarStyle = pbSolid
  617.         ProgBar10.BarStyle = pbSolid
  618.         ProgBar11.BarStyle = pbSolid
  619.         ProgBar12.BarStyle = pbSolid
  620.     Else
  621.         chkGradient.Value = Checked
  622.         chkGradient_Click
  623.     End If
  624. End Sub
  625. Private Sub chkWaitForSound_Click()
  626.     If chkWaitForSound.Value = Checked Then
  627.         ProgBar12.WaitForSound = True
  628.     Else
  629.         ProgBar12.WaitForSound = False
  630.     End If
  631. End Sub
  632. Private Sub cmdRunBars_Click()
  633.     'Declare the looping variables.
  634.     Dim i As Integer
  635.     'Set the mouse pointer busy.
  636.     Screen.MousePointer = 11
  637.            
  638.     'Loop through the limits.
  639.     For i = ProgBar1.Min To ProgBar1.Max
  640.         ProgBar1.Value = i
  641.         ProgBar2.Value = i
  642.         ProgBar3.Value = i
  643.         ProgBar4.Value = i
  644.         ProgBar5.Value = i
  645.         ProgBar6.Value = i
  646.         ProgBar7.Value = i
  647.         ProgBar8.Value = i
  648.         ProgBar9.Value = i
  649.         ProgBar10.Value = i
  650.         ProgBar11.Value = i
  651.         ProgBar12.Value = i
  652.     Next i
  653.     'And back again.
  654.     For i = ProgBar1.Max - 1 To ProgBar1.Min Step -1
  655.         ProgBar1.Value = i
  656.         ProgBar2.Value = i
  657.         ProgBar3.Value = i
  658.         ProgBar4.Value = i
  659.         ProgBar5.Value = i
  660.         ProgBar6.Value = i
  661.         ProgBar7.Value = i
  662.         ProgBar8.Value = i
  663.         ProgBar9.Value = i
  664.         ProgBar10.Value = i
  665.         ProgBar11.Value = i
  666.         ProgBar12.Value = i
  667.     Next i
  668.     'Set the mouse pointer normal.
  669.     Screen.MousePointer = 0
  670. End Sub
  671. Private Sub cmdSoundToPlay_Click()
  672. On Error GoTo Cancel_Error
  673.     'Get the sound file.
  674.     CommonDialog1.CancelError = True
  675.     CommonDialog1.Flags = cdlOFNHideReadOnly
  676.     CommonDialog1.Filter = "Wav Files|*.wav"
  677.     CommonDialog1.ShowOpen
  678.     txtSoundToPlay.Text = CommonDialog1.filename
  679. Cancel_Error:
  680. End Sub
  681. Private Sub Command1_Click()
  682. On Error GoTo Cancel_Error
  683.     'Get the colour.
  684.     CommonDialog1.CancelError = True
  685.     CommonDialog1.ShowColor
  686.     txtBackColour.Text = "&H00" & Trim(Hex$(CommonDialog1.Color)) & "&"
  687. Cancel_Error:
  688. End Sub
  689. Private Sub Command2_Click()
  690. On Error GoTo Cancel_Error
  691.     'Get the colour.
  692.     CommonDialog1.CancelError = True
  693.     CommonDialog1.ShowColor
  694.     txtBarStartColour.Text = "&H00" & Trim(Hex$(CommonDialog1.Color)) & "&"
  695. Cancel_Error:
  696. End Sub
  697. Private Sub Command3_Click()
  698. On Error GoTo Cancel_Error
  699.     'Get the colour.
  700.     CommonDialog1.CancelError = True
  701.     CommonDialog1.ShowColor
  702.     txtFontColour.Text = "&H00" & Trim(Hex$(CommonDialog1.Color)) & "&"
  703. Cancel_Error:
  704. End Sub
  705. Private Sub Command4_Click()
  706. On Error GoTo Cancel_Error
  707.     'Get the colour.
  708.     CommonDialog1.CancelError = True
  709.     CommonDialog1.ShowColor
  710.     txtBarEndColour.Text = "&H00" & Trim(Hex$(CommonDialog1.Color)) & "&"
  711. Cancel_Error:
  712. End Sub
  713. Private Sub txtBackColour_Change()
  714.     ProgBar1.BackColour = Val(txtBackColour.Text)
  715.     ProgBar2.BackColour = Val(txtBackColour.Text)
  716.     ProgBar3.BackColour = Val(txtBackColour.Text)
  717.     ProgBar4.BackColour = Val(txtBackColour.Text)
  718.     ProgBar5.BackColour = Val(txtBackColour.Text)
  719.     ProgBar6.BackColour = Val(txtBackColour.Text)
  720.     ProgBar7.BackColour = Val(txtBackColour.Text)
  721.     ProgBar8.BackColour = Val(txtBackColour.Text)
  722.     ProgBar9.BackColour = Val(txtBackColour.Text)
  723.     ProgBar10.BackColour = Val(txtBackColour.Text)
  724.     ProgBar11.BackColour = Val(txtBackColour.Text)
  725.     ProgBar12.BackColour = Val(txtBackColour.Text)
  726.     txtColour1.BackColor = Val(txtBackColour.Text)
  727. End Sub
  728. Private Sub txtBarEndColour_Change()
  729.     ProgBar1.BarEndColour = Val(txtBarEndColour.Text)
  730.     ProgBar2.BarEndColour = Val(txtBarEndColour.Text)
  731.     ProgBar3.BarEndColour = Val(txtBarEndColour.Text)
  732.     ProgBar4.BarEndColour = Val(txtBarEndColour.Text)
  733.     ProgBar5.BarEndColour = Val(txtBarEndColour.Text)
  734.     ProgBar6.BarEndColour = Val(txtBarEndColour.Text)
  735.     ProgBar7.BarEndColour = Val(txtBarEndColour.Text)
  736.     ProgBar8.BarEndColour = Val(txtBarEndColour.Text)
  737.     ProgBar9.BarEndColour = Val(txtBarEndColour.Text)
  738.     ProgBar10.BarEndColour = Val(txtBarEndColour.Text)
  739.     ProgBar11.BarEndColour = Val(txtBarEndColour.Text)
  740.     ProgBar12.BarEndColour = Val(txtBarEndColour.Text)
  741.     txtColour3.BackColor = Val(txtBarEndColour.Text)
  742. End Sub
  743. Private Sub txtBarStartColour_Change()
  744.     ProgBar1.BarStartColour = Val(txtBarStartColour.Text)
  745.     ProgBar2.BarStartColour = Val(txtBarStartColour.Text)
  746.     ProgBar3.BarStartColour = Val(txtBarStartColour.Text)
  747.     ProgBar4.BarStartColour = Val(txtBarStartColour.Text)
  748.     ProgBar5.BarStartColour = Val(txtBarStartColour.Text)
  749.     ProgBar6.BarStartColour = Val(txtBarStartColour.Text)
  750.     ProgBar7.BarStartColour = Val(txtBarStartColour.Text)
  751.     ProgBar8.BarStartColour = Val(txtBarStartColour.Text)
  752.     ProgBar9.BarStartColour = Val(txtBarStartColour.Text)
  753.     ProgBar10.BarStartColour = Val(txtBarStartColour.Text)
  754.     ProgBar11.BarStartColour = Val(txtBarStartColour.Text)
  755.     ProgBar12.BarStartColour = Val(txtBarStartColour.Text)
  756.     txtColour2.BackColor = Val(txtBarStartColour.Text)
  757. End Sub
  758. Private Sub txtFontColour_Change()
  759.     ProgBar1.FontColour = Val(txtFontColour.Text)
  760.     ProgBar2.FontColour = Val(txtFontColour.Text)
  761.     ProgBar3.FontColour = Val(txtFontColour.Text)
  762.     ProgBar4.FontColour = Val(txtFontColour.Text)
  763.     ProgBar5.FontColour = Val(txtFontColour.Text)
  764.     ProgBar6.FontColour = Val(txtFontColour.Text)
  765.     ProgBar7.FontColour = Val(txtFontColour.Text)
  766.     ProgBar8.FontColour = Val(txtFontColour.Text)
  767.     ProgBar9.FontColour = Val(txtFontColour.Text)
  768.     ProgBar10.FontColour = Val(txtFontColour.Text)
  769.     ProgBar11.FontColour = Val(txtFontColour.Text)
  770.     ProgBar12.FontColour = Val(txtFontColour.Text)
  771.     txtColour4.BackColor = Val(txtFontColour.Text)
  772. End Sub
  773. Private Sub txtLowerLimit_Change()
  774.     ProgBar1.Min = Val(txtLowerLimit.Text)
  775.     ProgBar2.Min = Val(txtLowerLimit.Text)
  776.     ProgBar3.Min = Val(txtLowerLimit.Text)
  777.     ProgBar4.Min = Val(txtLowerLimit.Text)
  778.     ProgBar5.Min = Val(txtLowerLimit.Text)
  779.     ProgBar6.Min = Val(txtLowerLimit.Text)
  780.     ProgBar7.Min = Val(txtLowerLimit.Text)
  781.     ProgBar8.Min = Val(txtLowerLimit.Text)
  782.     ProgBar9.Min = Val(txtLowerLimit.Text)
  783.     ProgBar10.Min = Val(txtLowerLimit.Text)
  784.     ProgBar11.Min = Val(txtLowerLimit.Text)
  785.     ProgBar12.Min = Val(txtLowerLimit.Text)
  786. End Sub
  787. Private Sub txtMessage_Change()
  788.     ProgBar1.Message = Trim(txtMessage.Text)
  789.     ProgBar2.Message = Trim(txtMessage.Text)
  790.     ProgBar3.Message = Trim(txtMessage.Text)
  791.     ProgBar4.Message = Trim(txtMessage.Text)
  792.     ProgBar5.Message = Trim(txtMessage.Text)
  793.     ProgBar6.Message = Trim(txtMessage.Text)
  794.     ProgBar7.Message = Trim(txtMessage.Text)
  795.     ProgBar8.Message = Trim(txtMessage.Text)
  796.     ProgBar9.Message = Trim(txtMessage.Text)
  797.     ProgBar10.Message = Trim(txtMessage.Text)
  798.     ProgBar11.Message = Trim(txtMessage.Text)
  799.     ProgBar12.Message = Trim(txtMessage.Text)
  800. End Sub
  801. Private Sub txtSoundToPlay_Click()
  802.     cmdSoundToPlay_Click
  803.     cmdSoundToPlay.SetFocus
  804. End Sub
  805. Private Sub txtSoundToPlay_Change()
  806.     ProgBar12.SoundToPlay = txtSoundToPlay.Text
  807. End Sub
  808. Private Sub txtUpperLimit_Change()
  809.     ProgBar1.Max = Val(txtUpperLimit.Text)
  810.     ProgBar2.Max = Val(txtUpperLimit.Text)
  811.     ProgBar3.Max = Val(txtUpperLimit.Text)
  812.     ProgBar4.Max = Val(txtUpperLimit.Text)
  813.     ProgBar5.Max = Val(txtUpperLimit.Text)
  814.     ProgBar6.Max = Val(txtUpperLimit.Text)
  815.     ProgBar7.Max = Val(txtUpperLimit.Text)
  816.     ProgBar8.Max = Val(txtUpperLimit.Text)
  817.     ProgBar9.Max = Val(txtUpperLimit.Text)
  818.     ProgBar10.Max = Val(txtUpperLimit.Text)
  819.     ProgBar11.Max = Val(txtUpperLimit.Text)
  820.     ProgBar12.Max = Val(txtUpperLimit.Text)
  821. End Sub
  822.